package com.che.software.testato.domain.entity;

import java.io.Serializable;

/**
 * Class representing a service of users with statistics.
 * 
 * @author Clement HELIOU (clement.heliou@che-software.com).
 * @copyright Che Software.
 * @license GNU General Public License.
 * @see Serializable
 * @since July, 2011.
 * 
 *        This file is part of Testato.
 * 
 *        Testato is free software: you can redistribute it and/or modify it
 *        under the terms of the GNU General Public License as published by the
 *        Free Software Foundation, either version 3 of the License, or (at your
 *        option) any later version.
 * 
 *        Testato is distributed in the hope that it will be useful, but WITHOUT
 *        ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
 *        FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
 *        for more details.
 * 
 *        You should have received a copy of the GNU General Public License
 *        along with Testato. If not, see <http://www.gnu.org/licenses/>.
 * 
 *        Testato's logo is a creation of Arrioch
 *        (http://arrioch.deviantart.com/) and it's distributed under the terms
 *        of the Creative Commons License.
 */
public class StatisticalService implements Serializable {

	/**
	 * Constants
	 */
	private static final long serialVersionUID = 7860886924276106152L;

	/**
	 * Members.
	 */
	private Integer userId;
	private Long usersNumber;
	private Service service;
	private User lastHiredUser;

	/**
	 * Default builder.
	 */
	public StatisticalService() {
	}

	/**
	 * Builder from fields.
	 * 
	 * @param usersNumber the users number in the service.
	 * @param service the service.
	 * @param userId the id of the last user hired by the service.
	 */
	public StatisticalService(Long usersNumber, Service service, Integer userId) {
		super();
		this.usersNumber = usersNumber;
		this.service = service;
		this.userId = userId;
	}

	/**
	 * Getter for the private field value usersNumber.
	 * 
	 * @return the usersNumber field value.
	 */
	public Long getUsersNumber() {
		return usersNumber;
	}

	/**
	 * Setting a value to the usersNumber field.
	 * 
	 * @param usersNumber the value to set.
	 */
	public void setUsersNumber(Long usersNumber) {
		this.usersNumber = usersNumber;
	}

	/**
	 * Getter for the private field value service.
	 * 
	 * @return the service field value.
	 */
	public Service getService() {
		return service;
	}

	/**
	 * Setting a value to the service field.
	 * 
	 * @param service the value to set.
	 */
	public void setService(Service service) {
		this.service = service;
	}

	/**
	 * Getter for the private field value lastHiredUser.
	 * 
	 * @return the lastHiredUser field value.
	 */
	public User getLastHiredUser() {
		return lastHiredUser;
	}

	/**
	 * Setting a value to the lastHiredUser field.
	 * 
	 * @param lastHiredUser the value to set.
	 */
	public void setLastHiredUser(User lastHiredUser) {
		this.lastHiredUser = lastHiredUser;
	}

	/**
	 * Getter for the private field value userId.
	 * 
	 * @return the userId field value.
	 */
	public Integer getUserId() {
		return userId;
	}

	/**
	 * Setting a value to the userId field.
	 * 
	 * @param userId the value to set.
	 */
	public void setUserId(Integer userId) {
		this.userId = userId;
	}
}